<template>
	<view>
		<z-common-box padding="18px 0" marginTop="32rpx" radius="40rpx">
			<view class="text-center font-color-666 font-size-14">
				<text>参与人数</text>
				<text class="font-color-theme_title font-w-bold ml-6 mr-6">{{user_count}}</text>
				<text>人</text>
			</view>
		</z-common-box>
		<!-- <view class="flex flex-dir-col align-center flex-js-center pa-16">
			<view class="flex flex-ai-center flex-js-sb font-size-12 mb-16" style="color: #979997;">
				<view class="zhanbi2">用户</view>
				<view class="zhanbi1">抽签码数量</view>
			</view>
			<view v-for="(item,index) in list" :key="index" :class="index%2 == 0?'bg_jb':''" class="item_box flex flex-ai-center flex-js-sb font-size-13 font-color-theme_title">
				<view class="zhanbi2 flex flex-ai-center">
					<image :src="$ossUrl + item.avatar" style="width: 24px;height: 24px;border-radius: 100%;"></image>
					<view class="is_show_1">{{item.nickname}}</view>
				</view> 
				<view class="zhanbi1 font-color-theme">{{item.nums}}</view>
			</view>
			<u-empty v-if="!list.length"></u-empty>
		</view>	 -->	
	</view>
</template>

<script>
	import { joinuser } from "@/api/draw/index.js"
	export default {
		name:'joinUsers',
		props:{
			form:{
				type:Object
			}
		},
		data(){
			return {
				page:0,
				list:[],
				user_count:0
			}
		},
		methods:{
			getList(){
				this.page++
				let data = {...this.form,page:this.page}
				joinuser(data).then( res => {
					this.list = this.list.concat( res.data.list )
					if(this.page == 1) this.user_count = res.data.user_count
				}).catch( err => {} )
			},
			onRefresh(){
				this.page = 0
				this.list = []
				this.getList()
			}
		}
	}
</script>

<style scoped lang="scss">
	.zhanbi {
		width: 5%;
		text-align: center;
	}
	.zhanbi1 {
		width: 45%;
		text-align: center;
	}
	.zhanbi2 {
		width: 45%;
		text-align: center;
		justify-content: center;
		margin-left: 5%;
	}
	.item_box {
		width: 100%;
		height: 80rpx;
		border-radius: 8px 0px 0px 8px;
	}
	.bg_jb {
		background: linear-gradient(90deg, #91EDF3 0%, rgba(145,243,243,0) 100%);
	}
</style>